import time
from selenium import webdriver
from seleniumrequests import Chrome
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
import json
from bs4 import BeautifulSoup

headers = {
    "Content-Type": "application/json;charset=UTF-8"
}
params = '{"userName":"portz","password":"Achui_19800724","productLine":"IFP","allianceId":"","toPage":"","auctionId":"","bidId":""}'
postdata = json.loads(params)

options = webdriver.ChromeOptions()
options.add_argument('headless')
driver = webdriver.Chrome(executable_path='D:/python/pytho-demo/chromedriver.exe', chrome_options=options)  # Optional argument, if not specified will search path.
driver.set_page_load_timeout(500)
r = driver.get("https://www.paypal-community.com/t5/PayPal-Community/ct-p/en")
#r = driver.get("https://cmc.tools/")
#driver.get('https://www9.qa.ehealthinsurance.com/bov2/index.html#/liveopsmapping?t=36490')
search = WebDriverWait(driver, 30).until(EC.presence_of_all_elements_located((By.CLASS_NAME, "lia-list-slim")))
soup = BeautifulSoup(driver.page_source, "lxml")
elements = soup.find_all(class_="lia-list-slim")
for ele in elements:
    print(ele.a["href"])
